﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using DataService.LocalFile;
using DataService.Database;

namespace DataService
{
    /// <summary>
    /// 
    /// </summary>
    public class JskeDataService
    {
        public IDataService dbWorker;
        public const int LOCAL_FILE_MODE = 0;
        public const int MSSQL_MODE = 1;
        public JskeDataService()
        {
            dbWorker = new LocalFileDataServiceImpl();
        }
        public JskeDataService(int mode)
        {
            if (mode == LOCAL_FILE_MODE)
            {
                dbWorker = new LocalFileDataServiceImpl();
            }
            else if (mode == MSSQL_MODE)
            {
                dbWorker = new MSSQLDataServiceImpl();
            }
            else
            {
                dbWorker = new LocalFileDataServiceImpl();
            }

        }

    }
}
